home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1998 July / EnigmA AMIGA RUN 29 (1998)(G.R. Edizioni)(IT)[!][issue 1998-07 & 08].iso / earcd / utils / vinced / include / menu.h < prev    next >
C/C++ Source or Header  |  1997-07-29  |  3KB  |  91 lines

  1. #ifndef VNC_MENU_H
  2. #define VNC_MENU_H
  3. /*********************************************************
  4.  ** ViNCEd                                              **
  5.  ** a DOS - window handler                              **
  6.  **                                                     **
  7.  ** © 1991-97 THOR-Software inc.                        **
  8.  ** Version 3.30                                        **
  9.  **                                                     **
  10.  ** program version 1.23 05/03/91       THOR            **
  11.  ** update  version 1.25 06/19/91       THOR            **
  12.  ** header file 06/19/91                THOR            **
  13.  ** updated to 3.30      03/31/97       THOR            **
  14.  **                                                     **
  15.  ** ViNCEd Menu constructor                             **
  16.  **-----------------------------------------------------**
  17.  **                                                     **
  18.  ** all use at your own risk,etc.,etc.                  **
  19.  **                                                     **
  20.  ** Everything declared as "reserved" or                **
  21.  ** "not used" is NOT free for your use,                **
  22.  ** it will propably used in a later release.           **
  23.  ** All FREE entries are free for public                **
  24.  ** use and are, if not otherwise noticed,              **
  25.  ** initialized as ZERO                                 **
  26.  *********************************************************/
  27.  
  28. #ifndef EXEC_TYPES_H
  29. #include <exec/types.h>
  30. #endif
  31.  
  32. struct ViNCMenu {
  33.         UBYTE           vmc_Type;       /* see definitions below */
  34.         UBYTE           vmc_Flags;      /* flags for intuition,
  35.                                            goes to flags fields, lo byte */
  36.         char            vmc_Shortcut;   /* shortcut character, if any */
  37.         char            vmc_Text[1];    /* title goes here. MUST be NUL
  38.                                            terminated string, more than one
  39.                                            character is allowed, of course,
  40.                                            but C syntax is too limiting to
  41.                                            define it differently.
  42.                                         */
  43. };
  44.  
  45. /* The whole menu is simply a bunch of these structures, one followed
  46.    by another. The list is terminated with an item of type VMC_LASTMENU.
  47.    See the localization drawer sys1.asm for an example how this looks
  48.    like */
  49.  
  50. /* Type definitions */
  51.  
  52. /* a menu title */
  53. #define VMC_MENU        1
  54.  
  55. /* a menu item */
  56. #define VMC_MENUITEM    2
  57.  
  58. /* a subitem of an item */
  59. #define VMC_SUBITEM     3
  60.  
  61.  
  62. /* the last menu at all */
  63. #define VMC_LASTMENU    0x81
  64.  
  65. /* the last menu item in a menu */
  66. #define VMC_LASTITEM    0x82
  67.  
  68. /* the last subitem in a list of subitems */
  69. #define VMC_LASTSUBITEM 0x83
  70.  
  71. /* the last bit itself */
  72. #define VMC_LAST_BIT    7
  73. #define VMC_LAST_MASK   0x80
  74.  
  75. /* a bit that this is a special function, not a string */
  76. #define VMC_ISFUNC_BIT  6
  77. #define VMC_ISFUNC_MASK 0x40
  78.  
  79. /* the bits giving the function index and the type */
  80. #define VMC_FUNCMASK    0x3c
  81. #define VMC_FUNCSHIFT   2
  82. #define VMC_TYPEMASK    3
  83.  
  84. /* Shift by FUNCSHIFT to get the function index.
  85.    Functions 0..9 are the macro texts of macros 0..9
  86.    10 to 12 are the history,upper and lower size
  87.    13 to 15 are the copyright texts */
  88.  
  89. #endif
  90.  
  91.